<template>
    <view class="select_HunYin_cp">
        <u-radio-group v-model="selectData">
            <u-radio v-for="(item, index) in dataList" :key="index" :name="item.name" :disabled="item.disabled">
                {{ item.name }}
            </u-radio>
        </u-radio-group>
    </view>
</template>

<script>
//婚姻选择组件
export default {
    name:"SelectHunYinCp",
    props:{
        value:{
            type:String,
            default:'',
        },
    },
    data() {
        return {
            dataList: [
                {
                    name: '已婚',
                    disabled: false,
                },
                {
                    name: '未婚',
                    disabled: false,
                },
            ],
        }
    },
    computed:{
        selectData:{
            get(){
                return this.value;
            },
            set(value){
                this.$emit('input',value);
            },
        },
    },
}
</script>

<style lang="scss" scoped>
.select_HunYin_cp {
    text-align: center;
    width: 100%;
    /deep/.u-input{
        width: 100%;
    }
}
</style>
